package cn.com.cifi.mars.constant;

/**
 * 条件类型(0默认 1或 2且)
 * @author Administrator
 *
 */
public enum ConditionTypeEnum {
	ZERO("0", "默认"), 
	ONE("1", "或"), 
	TWO("2", "且");

	private String key;
	private String value;

	ConditionTypeEnum(String key, String value) {
		this.key = key;
		this.value = value;
	}

	/**
	 * @return the key
	 */
	public String getKey() {
		return key;
	}
	/**
	 * @return the value
	 */
	public String getValue() {
		return value;
	}

   
	public static String getValueByKey(String key) {
		for (ConditionTypeEnum versionTypeEunm : ConditionTypeEnum.values()) {
			if (key.equals(versionTypeEunm.getKey())) {
				return versionTypeEunm.getValue();
			}
		}
		return null;
	}
}
